package com.fare.taluo.queue;

import com.dayatang.domain.InstanceFactory;
import com.fare.taluo.application.queue.IScheduleQueueApplication;
import com.fare.taluo.application.queue.QueueSMSMessageApplication;
import com.fare.taluo.queue.template.ScheduleQueueTemplate;
import com.fare.taluo.vo.queue.QueueSMSMessageVO;
/**
 * 短信发送队列实现类
 * <p>threahpool-config.xml中配置名称
 * @author creator: xiangsf
 * @author modifior: xiangsf
 * @since 2012-12-20-上午8:52:45
 * @version v1.0
 */
public class ScheduleQueueSMSMessage extends ScheduleQueueTemplate<ScheduleQueueSMSMessage, QueueSMSMessageVO> {

	public static final String SCHEDULE_QUEUE_ID = "SMSMessage";
	
	private QueueSMSMessageVO vo;

	public ScheduleQueueSMSMessage(){}
	
	public ScheduleQueueSMSMessage(QueueSMSMessageVO vo){
		this.vo = vo;
	}
	
	@Override
	public IScheduleQueueApplication<QueueSMSMessageVO> getApplication() {
		return InstanceFactory.getInstance(QueueSMSMessageApplication.class, "queueSMSMessageApplication");
	}

	@Override
	public ScheduleQueueSMSMessage delegate(QueueSMSMessageVO vo) {
		return new ScheduleQueueSMSMessage(vo);
	}

	@Override
	public QueueSMSMessageVO getDelegateSource() {
		return vo;
	}
}
